package cn.ggcms.cms.action.comment;

import java.util.List;

import cn.ggcms.cms.biz.CommentBiz;
import cn.ggcms.cms.vo.Comment;

import com.opensymphony.xwork2.ActionSupport;

public class CommentAction extends ActionSupport {
	private static final long serialVersionUID = 1L;
	private CommentBiz commentBiz;
	private List<Comment> comments;
	private Comment comment;

	public CommentBiz getCommentBiz() {
		return commentBiz;
	}

	public void setCommentBiz(CommentBiz commentBiz) {
		this.commentBiz = commentBiz;
	}

	public List<Comment> getComments() {
		return comments;
	}

	public void setComments(List<Comment> comments) {
		this.comments = comments;
	}

	public String execute() throws Exception {
		// TODO Auto-generated method stub
		return super.execute();
	}

	public String getAll() throws Exception {
		comments = commentBiz.finComments();
		return "getAllSuccess";
	}

	public String upload() throws Exception {
		commentBiz.doUpdateComment(comment);
		return null;

	}

}
